Problems tagged with "naive bayes"

Problem #044

Tags: naive bayes

Consider the below data set which collects information on 10 pets:

Suppose a new pet is friendly and sheds fur. What does a Na\"ive Bayes classifier predict for its species?

Solution

Cat.

Problem #045

Tags: naive bayes

Suppose a data set of 100 points in 10 dimensions is used in a binary classification task; that is, each point is labeled as either a 1 or a 0.

If Gaussian Naive Bayes is trained on this data, how many univariate Gaussians will be fit?

Problem #057

Tags: naive bayes

Consider the below data set which collects information on the weather on 10 days:

Suppose a new day is not sunny but is warm. What does a Na\"ive Bayes classifier predict for whether it rained?

Solution

Yes, it rained.

Problem #097

Tags: naive bayes

Consider the below data set collecting information on a set of 10 flowers.

What species does a Naive Bayes classifier predict for a flower with 3 petals and no leaves?

Solution

B. Video explanation: https://youtu.be/iKPAhJJcu6s

Problem #105

Tags: naive bayes

Does standardizing the data possibly change the prediction made by Gaussian Naive Bayes?

More precisely, let \((\nvec{x}{1}, y_1), \ldots, (\nvec{x}{n}, y_n)\) be a set of training data for a binary classification problem, where each \(\nvec{x}{i}\in\mathbb R^d\) and each \(y_i \in\{0, 1\}\). Suppose that when a Gaussian Na\"ive Bayes classifier is trained on this data set, \(\nvec{x}{1}\) is predicted to be from Class \(0\).

Now suppose that the data set is standardized by subtracting the mean of each feature and dividing by its standard deviation. This is done for the data set as a whole, not separately for each class. Let \(\nvec{z}{1}, \ldots, \nvec{z}{n}\) be the standardized data set.

True or False: when a Gaussian Na\"ive Bayes classifier is trained on the standardized data set, it must still predict \(\nvec{z}{1}\) to be from Class \(0\).

True False
Solution

True.

Video explanation: https://youtu.be/hGlWsEk_tYI